:global {
  .editorHead {
    text-align: center;

    >h1 {
      color: inherit;
      font-weight: 700;
      font-size: 2.5rem;
      line-height: 1rem;
      line-height: 1.5;
      text-align: center;
      border: 0 !important;
    }

    >p {
      margin-bottom: 1.2em;
      color: inherit;
      font-style: italic;
      text-align: center;
    }
  }

  .level2 {}
}

.DetailPage {
  padding-top: 16px;
  background: var(--bg-body);

  header {
    box-sizing: border-box;
    margin: 0;
    font-variant: tabular-nums;
    line-height: 1.5;
    list-style: none;
    font-feature-settings: 'tnum';
    color: rgba(0, 0, 0, 0.85);
    font-size: 14px;
    color: var(--second-text-color) !important;
  }
}

.DetailPagecCantainer {
  margin-top: 1rem;
  display: flex;
}

.DetailPageLeft {
  width: calc(100% - 20rem);
  font-size: 14px;
  background: var(--bg-body);
  margin-left: 0;

  .comment {
    width: 100%;
    position: relative;
    padding: 16px;
    border-radius: var(--border-radius);
    margin-bottom: 16px;
    background-color: var(--bg-second);
    box-shadow: var(--box-shadow);

    textarea {
      min-width: 100%;
      border-color: var(--comment-editor-border-color);
      color: var(--main-text-color);
      background-color: var(--bg-second);
      line-height: 1.5;
      vertical-align: bottom;
      transition: all 0.3s, height 0s;
    }
  }

  >header {
    margin-bottom: 1rem;
    color: var(--main-text-color);
    font-weight: 600;
    font-size: 16px;
    line-height: 22px;
  }

  >main {
    width: 100%;
    background-color: var(--bg-second);
    padding: .8rem;
    box-shadow: var(--box-shadow);
    border-radius: var(--border-radius);
    margin: 1rem auto;
    overflow: hidden;
  }
}

.DetailPageRight {
  width: 20rem;
  padding-left: 1rem;
  .sticky {
    position: sticky;
    position: -webkit-sticky;
    top: 1rem;
  }
  .DetailPageRightTop {
    overflow-y: hidden;
    padding-top: 1rem;
    padding-bottom: 2rem;
    padding-left: 1rem;
    border-radius: 5px;
    background: var(--bg-second);

    ::-webkit-scrollbar {
      width: 6px;
      /*对垂直流动条有效*/
      height: 6px;
      /*对水平流动条有效*/
    }

    /*定义滚动条的轨道颜色、内阴影及圆角*/
    ::-webkit-scrollbar-track {
      // -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,.3);
      background-color: var(--bg);
      border-radius: 3px;
    }

    /*定义滑块颜色、内阴影及圆角*/
    ::-webkit-scrollbar-thumb {
      border-radius: 7px;
      -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, .3);
      background-color: #E8E8E8;
    }

    /*定义两端按钮的样式*/
    ::-webkit-scrollbar-button {
      background-color: var(--bg);
    }

    /*定义右下角汇合处的样式*/
    ::-webkit-scrollbar-corner {
      background: khaki;
    }

    header {
      color: var(--main-text-color);
      font-weight: 600;
      font-size: 16px;
      line-height: 22px;
      margin-bottom: 12px;
    }

    >ul {
      height: 100%;
      list-style: none;
      padding: 0;
      margin: 0;
      overflow-y: auto;

      ::-webkit-scrollbar {
        width: 1px;
      }

      >li {
        border-radius: var(--border-radius);
        display: list-item;
        text-align: -webkit-match-parent;
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        height: 32px;
        font-size: 14px;
        line-height: 20px;
        padding-left: 12px;
        padding-right: 16px;
      }

      >li:hover {
        color: var(--primary-color);
      }
    }
  }

  .DetailPageRightBottom {
    width: 320px;
    height: 254px;
    padding: .8rem 0;
    border-radius: var(--border-radius);

    header {
      color: var(--main-text-color);
      font-weight: 600;
      line-height: 22px;
      margin-bottom: 12px;
    }

    >main {
      position: relative;
      max-height: 50vh;
      padding: 0 10px;
      overflow: auto;



      >li {
        list-style: outside;
        position: relative;
        z-index: 10;
        padding: 10px 0 10px 12px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        padding-left: 12px;
        cursor: pointer;
        --dot-left: 0px;
        --dot-width: 6px;
      }
    }

    ::-webkit-scrollbar {
      width: 6px;
      /*对垂直流动条有效*/
      /*对水平流动条有效*/
    }

    /*定义滚动条的轨道颜色、内阴影及圆角*/
    ::-webkit-scrollbar-track {
      // -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,.3);
      // background-color: var(--bg);
      border-radius: 3px;
    }

    /*定义滑块颜色、内阴影及圆角*/
    ::-webkit-scrollbar-thumb {
      border-radius: 7px;
      -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, .3);
      background-color: #E8E8E8;
    }

    /*定义两端按钮的样式*/
    ::-webkit-scrollbar-button {
      // background-color: var(--bg);
    }

    /*定义右下角汇合处的样式*/
    // ::-webkit-scrollbar-corner {
    //   // background: khaki;
    // }


  }



}


@media (min-width: 1200px) and (max-width:1920px) {
  .DetailPage {
    width: 1140px;
  }
}

@media (min-width: 992px) and (max-width:1199px) {
  .DetailPage {
    width: 970px;
  }
}

@media (min-width: 768px) and (max-width:919px) {
  .DetailPage {
    width: 768px;
  }
}

@media (max-width:780px) {
  .DetailPage {
    .cantainerMainRight {
      display: none;
    }
  }

}

// markdown
.markdown {
  background: var(--bg-second);
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  padding: 0;
  margin: 0;
  color: var(--main-text-color);
  font-size: 14px;
  line-height: 1.75;
  letter-spacing: 2px;
  font-family: Optima-Regular, Optima, PingFangTC-Light, PingFangSC-light, PingFangTC-light;
  text-indent: 1rem;
  padding-left: 1rem;
  padding-right: 1rem;
  padding-bottom: 2rem;

  .detailButton {
    display: flex;
    flex-direction: row;
    width: 100%;
    margin-top: 2rem;
    padding-left: 2rem;
    padding-right: 2rem;

    >div {
      height: 3.6rem;
      flex: 1;
      padding: 8px;
      border-radius: var(--border-radius);
      background: var(--bg-second);
      border: 1px solid var(--border-color);
      box-shadow: var(--box-shadow);
      overflow: hidden;
      line-height: 38px;

    }

    >div:hover {
      border: var(--primary-color) 1px solid;
    }

    div:nth-child(2) {
      text-align: right;
      margin-left: 2rem;


    }

    div:nth-child(1) {
      text-align: left;
      margin-right: 2rem;
    }
  }

  p {
    margin: 10px 0;
    color: inherit;
    font-size: 14px;
    letter-spacing: 2px;
    word-spacing: 2px;
  }

  h2 {
    display: inline-block;
    width: 100%;
    border-bottom: 0;
    margin: 20px 10px 0 0 !important;
    font-weight: bold;
    font-size: 18px;
    text-align: left;
  }

  h3 {
    border-bottom: 2px solid var(--border-color);
    font-weight: bold;
    font-size: 16px;
    text-align: left;
  }

  .hljs-string,
  .hljs-regexp,
  .hljs-addition,
  .hljs-attribute,
  .hljs-meta-string {
    color: #50a14f;
  }

  pre {
    position: relative;
    max-height: 400px;
    padding-top: 30px;
    border-radius: 5px;
    margin: 10px 0;
    background-color: var(--bg-code);
    font-size: 1em;
    overflow-y: auto !important;
    overflow-x: hidden !important;


    &::before {
      position: absolute;
      top: 0;
      display: block;
      width: 100%;
      height: 30px;
      background-image: url(https://wipi.oss-cn-shanghai.aliyuncs.com/2020-07-12/97e4eed2-a992-4976-acf0-ccb6fb34d308.png);
      background-position: 10px 10px;
      background-size: 40px;
      background-repeat: no-repeat;
      background-color: var(--bg-code);
      content: '';
    }

    .copy-code-btn {
      position: absolute;
      top: 9px;
      right: 15px;
      font-size: 12px;
      line-height: 1;
      cursor: pointer;
      color: rgba(140, 140, 140, 0.8);
      transition: color .1s;
    }

    code {
      display: block;
      max-height: 370px;
      padding: 12px 10px;
      padding-top: 9px;
      border-radius: 0;
      color: var(--main-text-color);
      background-color: var(--bg-code);
      overflow: hidden;
      overscroll-behavior: contain;
      font-size: 12px;
      margin: 0;
      white-space: pre-wrap;

      &::before {
        content: 'shell';
      }

      .hljs-symbol,
      .hljs-bullet,
      .hljs-link,
      .hljs-meta,
      .hljs-selector-id,
      .hljs-title {
        color: #4078f2;
      }
    }
  }


  ::-webkit-scrollbar {
    width: 6px;
    /*对垂直流动条有效*/
    height: 6px;
    /*对水平流动条有效*/
  }

  /*定义滚动条的轨道颜色、内阴影及圆角*/
  ::-webkit-scrollbar-track {
    // -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,.3);
    background-color: var(--bg);
    border-radius: 3px;
  }

  /*定义滑块颜色、内阴影及圆角*/
  ::-webkit-scrollbar-thumb {
    border-radius: 7px;
    -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, .3);
    background-color: #E8E8E8;
  }

  /*定义两端按钮的样式*/
  ::-webkit-scrollbar-button {
    background-color: var(--bg);
  }

  /*定义右下角汇合处的样式*/
  ::-webkit-scrollbar-corner {
    background: khaki;
  }
}


// var scrollStyle ::-webkit-scrollbar {
//   width: 6px;
//   /*对垂直流动条有效*/
//   height: 6px;

//   /*对水平流动条有效*/
//   /*定义滚动条的轨道颜色、内阴影及圆角*/
//   ::-webkit-scrollbar-track {
//     // -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,.3);
//     background-color: var(--bg);
//     border-radius: 3px;
//   }

//   /*定义滑块颜色、内阴影及圆角*/
//   ::-webkit-scrollbar-thumb {
//     border-radius: 7px;
//     -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, .3);
//     background-color: #E8E8E8;
//   }

//   /*定义两端按钮的样式*/
//   ::-webkit-scrollbar-button {
//     background-color: var(--bg);
//   }

//   /*定义右下角汇合处的样式*/
//   ::-webkit-scrollbar-corner {
//     background: khaki;
//   }
// }
